package com.xiyu.service.vo.mailbox.folder.baseVO;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;
import jakarta.validation.constraints.*;
import org.hibernate.validator.constraints.*;

import static com.xiyu.service.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;

/**
 * 邮箱账号文件夹 Base VO，提供给添加、修改、详细的子 VO 使用
 * 如果子 VO 存在差异的字段，请不要添加到这里，影响 Swagger 文档生成
 */
@Data
public class MailboxFolderBase {

    @Schema(description = "邮箱账号ID")
    private Long accountId;

    @Schema(description = "文件夹名称")
    @Size(max = 50, message = "文件夹名称长度不能超过50")
    private String name;

    @Schema(description = "邮局文件夹名称")
    @Size(max = 255, message = "邮局文件夹名称长度不能超过255")
    private String postOfficeName;

    @Schema(description = "邮件数量")
    @Range(max = 100000000, message = "邮件数量最大不能超过100000000")
    private Integer mailCount;

    @Schema(description = "置顶邮件数量")
    @Range(max = 100000000, message = "置顶邮件数量最大不能超过100000000")
    private Integer topMailCount;

    @Schema(description = "已读邮件数量")
    @Range(max = 100000000, message = "已读邮件数量最大不能超过100000000")
    private Integer readMailCount;

    @Schema(description = "父文件夹ID")
    private Long parentId;

    @Schema(description = "文件夹类型")
    @Range(max = 127, message = "文件夹类型最大不能超过127")
    private Integer folderType;

    @Schema(description = "排序")
    @Range(max = 100000000, message = "排序最大不能超过100000000")
    private Long sort;

    @Schema(description = "颜色")
    @Size(max = 50, message = "标签颜色长度不能超过50")
    private String color;

    @Schema(description = "文件夹分类")
    @Range(max = 127, message = "文件夹分类最大不能超过127")
    private Integer folderClass;

}
